#include "Shm.hpp"
#include "NamedPipe.hpp"

int main() {
    Shm shm(SHPathName, SHProj_Id, SHUser);
    shm.Zero();
    char* addr = (char*)shm.GetAddress();

    NamedPipe fifo(ComPath, NPUser);

    char ch = 'A';
    while (ch <= 'Z') {
        addr[ch - 'A'] = ch;
        std::cout << "add " << ch << " into shm " << "wakeup reader" << std::endl;
        ch++;
        std::string temp("wakeup");
        fifo.SomeoneUseForWrite(temp);
        sleep(2);
    }
    return 0;
}